<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<html>
<head>
    <title>i movie</title>
    <link rel="stylesheet" href="${pageContext.request.contextPath}/layui-v2.5.6/layui/css/layui.css">
    <script src="${pageContext.request.contextPath}/layui-v2.5.6/layui/layui.js"></script>
    <script src="${pageContext.request.contextPath}/js/jquery-3.4.1.min.js"></script>
    <script>
        $(function () {
            $('#exit').click(function () {
                $.cookie('userId',null,{ path: '/' });
                window.location.href = '${pageContext.request.contextPath}/backend/user/goLogin'
            });
            $('#user').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/user/user')
            });
            $('#type').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/user/type')
            })
            $('#area').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/user/area')
            })
            $('#year').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/user/year')
            })
            $('#banner').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/user/banner')
            })
            $('#movieAdd').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/movie/movieAdd')
            })
            $('#editMovie').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/movie/movieEdit')
            })
            $('#cinemaEdit').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/movie/cinemaEdit')
            })
            $('#cinemaAdd').click(function () {
                $('.layui-body').find('iframe').attr('src','${pageContext.request.contextPath}/backend/movie/cinemaAdd')
            })
        })
    </script>
</head>
<body class="layui-layout-body">
<div class="layui-layout layui-layout-admin">
    <div class="layui-header">
        <div class="layui-logo"><img src="${pageContext.request.contextPath}/images/logo.png" style="height: 45px;margin-top: 10px"></div>
        <ul class="layui-nav layui-layout-right">
            <li class="layui-nav-item">
                <a href="javascript:;">
                    <img src="${user.avatar}" class="layui-nav-img">
                    ${user.nickname}
                </a>
            </li>
            <li class="layui-nav-item"><span href="javascript:;" id="exit">退了</span></li>
        </ul>
    </div>

    <div class="layui-side layui-bg-black">
        <div class="layui-side-scroll">
            <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
            <ul class="layui-nav layui-nav-tree"  lay-filter="test">
                <li class="layui-nav-item layui-nav-itemed">
                    <a class="" href="javascript:;">电影管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="javascript:;" id="editMovie">修改电影</a></dd>
                        <dd><a href="javascript:;" id="movieAdd">添加电影</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item">
                    <a href="javascript:;">电影院管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="javascript:;" id="cinemaEdit">修改电影院</a></dd>
                        <dd><a href="javascript:;" id="cinemaAdd">添加电影院</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item">
                    <a href="javascript:;">元数据管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="javascript:;" id="type">电影类型管理</a></dd>
                        <dd><a href="javascript:;" id="area">电影地区管理</a></dd>
                        <dd><a href="javascript:;" id="year">电影年代管理</a></dd>
                        <dd><a href="javascript:;" id="banner">banner管理</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item"><a href="javascript:;" id="user">用户管理</a></li>
            </ul>
        </div>
    </div>

    <div class="layui-body">
        <div style="padding: 15px;"><iframe src="${pageContext.request.contextPath}/backend/movie/movieEdit" style="width: 100%;height: 100%" scrolling="no" frameborder="0"></iframe></div>
    </div>

    <div class="layui-footer">
        <!-- 底部固定区域 -->
        © i movie
    </div>
</div>
<script>
    //JavaScript代码区域
    layui.use('element', function(){
        var element = layui.element;
    });
</script>
</body>
</html>
